package com.kiki.stater;

import org.springframework.util.StopWatch;

/**
 * Created by mazeyi on 2021/2/25.
 */
public class StopWatchTest {

    public static void main(String[] args) {


            StopWatch stopWatch = new StopWatch();
            stopWatch.start("倒计时");
            try {
                Thread.sleep(3000);
            } catch (InterruptedException e) {
                e.printStackTrace();
            }
            System.out.println(stopWatch.currentTaskName());

            stopWatch.stop();

            System.out.println(stopWatch.getLastTaskTimeMillis());

    }
}